package demo1;

class Base{
    public int a=1;
    public int b=2;
}

class Derived extends Base{
    public int a=100;
    public int c=3;
    public void test(){
        System.out.println(a);
        System.out.println(super.a);//父类
        System.out.println(b);
        System.out.println(c);
    }
}

public class test3 {
    public static void main(String[] args) {
        Derived derived=new Derived();
        derived.test();
    }
}
